package com.example.mvvm.until;

import java.util.List;

/**
 * @Description
 * @Author 梁浩文
 * @Date 2021/10/9 17:07
 */
public class ListUtil {
    public static String jointString(String point, List value) {
        StringBuilder resultValue = new StringBuilder();
        if (value != null) {
            for (Object o : value) {
                resultValue.append(o).append(point);
            }
        }
        String s = resultValue.toString();
        boolean b = s.endsWith(",");
        if (b) {
            s = s.substring(0, resultValue.length() - point.length());
        }
        return s;
    }
}
